<script>
	// #ifdef H5
	(function() {
	  if (typeof WeixinJSBridge == 'object' && typeof WeixinJSBridge.invoke == 'function') {
	   handleFontSize();
	  } else {
	   if (document.addEventListener) {
	    document.addEventListener('WeixinJSBridgeReady', handleFontSize, false);
	   } else if (document.attachEvent) {
	    document.attachEvent('WeixinJSBridgeReady', handleFontSize);
	    document.attachEvent('onWeixinJSBridgeReady', handleFontSize);
	   }
	  }
	
	  function handleFontSize() {
	   // 设置网页字体为默认大小
	   WeixinJSBridge.invoke('setFontSizeCallback', {
	    'fontSize': 0
	   });
	   // 重写设置网页字体大小的事件
	   WeixinJSBridge.on('menu:setfont', function() {
	    WeixinJSBridge.invoke('setFontSizeCallback', {
	     'fontSize': 0
	    });
	   });
	  }
	 })();
	// #endif
	// 引入常用方法类
	import tools from './common/sju.tools.js'
	export default {
		onLaunch: function() {
			console.log('App Launch')
			this.getCurrentUserUpdateFlagFun()
		},
		onShow: function() {
			console.log('App Show')
			// #ifdef MP 
			tools.VersionUpdate() //小程序模式下检测小程序更新
			// #endif
		},
		onHide: function() {
			console.log('App Hide')
		},
		methods:{
			// 判断当前用户是否更新信息
			getCurrentUserUpdateFlagFun(){
				this.sjuRequest("wx/user/getCurrentUserUpdateFlag", 'POST',{}).then(res => {
					console.log('app-判断当前用户是否更新信息')
					console.log(res)
					uni.setStorageSync('isUserUpdateFlag',res.data)
					// this.bannerList = res.data
				})
			},
		}
	}
	
</script>

<style lang="scss">
	@import "@/static/iconfont.css";
	/*每个页面公共css */
	page{
		background-color: $bg-color;
		font-size: $font-size-base;
		color: $text-color;
		padding-bottom: 20rpx;
		width: 100%;
		overflow-x: hidden;
	}
	/* #ifdef H5 */
	body { /* IOS禁止微信调整字体大小 */
	            -webkit-text-size-adjust: 100% !important;
	            text-size-adjust: 100% !important;
	            -moz-text-size-adjust: 100% !important;
	}
	/* #endif */
	.uni-input{
		border: 1rpx solid #eee;
		width: 100%;
		height: 60rpx;
		line-height: 60rpx;
		margin: 0 auto;
		padding: 0 20rpx;
		font-size: 28rpx;
		box-sizing: border-box;
	}
	// 单行省略，优先使用 unocss: text-ellipsis
	.ellipsis {
	  overflow: hidden;
	  text-overflow: ellipsis;
	  white-space: nowrap;
	}
	
	// 两行省略
	.ellipsis-2 {
	  display: -webkit-box;
	  overflow: hidden;
	  text-overflow: ellipsis;
	  -webkit-line-clamp: 2;
	  -webkit-box-orient: vertical;
	}
	
	// 三行省略
	.ellipsis-3 {
	  display: -webkit-box;
	  overflow: hidden;
	  text-overflow: ellipsis;
	  -webkit-line-clamp: 3;
	  -webkit-box-orient: vertical;
	}
	.boxWrap {
	  box-sizing: border-box;
	  width: 100%;
	  height: auto;
	  background: #fff;
	  border-radius: 16rpx;
	  box-shadow: 8rpx 8rpx 8rpx rgba(0, 0, 0, 0.1);
	}
	.main {
	  width: 96%;
	  margin: 30rpx auto;
	}
	.flex{
		display: flex;
		align-items: center;
	}
	.nodata{
		width: 100%;
		height: auto;
	}
	.nodata_img{
		width: 400rpx;
		height: auto;
		display: block;
		margin: 30rpx auto;
		margin-bottom: 10rpx;
	}
	.nodata_c{
		width: 100%;
		height: auto;
		text-align: center;
	}
	.nodata{
		width: 100%;
		text-align: center;
	}
	.flex-between{
		justify-content: space-between;
	}
	.zhezhao {
		background-color: rgba(0, 0, 0, 0.5);
		width: 100%;
		height: 100vh;
		position: fixed;
		top: 0;
		left: 0;
		z-index: 9;
	}
</style>
